
package com.mephi.exception;

/**
 *
 * @author GM Mephisto
 */
public class IndexOutOfBoundsException extends java.lang.IndexOutOfBoundsException
{
	public IndexOutOfBoundsException()
    {
        super("Index is out of bounds!");
    }

    /**
     *
     * @param lowerBound - the lowest possible value
     * @param upperBound - the highest possible value
     * @param index - actual value of the parameter
     */
    public IndexOutOfBoundsException(int lowerBound, int upperBound, int index)
    {
        super("Lower bound: " + lowerBound + ", Upper bound: " + upperBound + ", index: " + index);
        this.lowerBound = lowerBound;
        this.upperBound = upperBound;
        this.index = index;
    }
    

    private static final long serialVersionUID = -6724171332239083115L;
    
    @SuppressWarnings("unused")
	private int lowerBound;
    @SuppressWarnings("unused")
	private int upperBound;
    @SuppressWarnings("unused")
    private int index;
}
